package org.icnmasjid.member.model;

/**
 * @struts.form include-all="true" extends="BaseForm"
 * @hibernate.class
 *         table="moodle_grade"
 *     
 */

public class MoodleGrade extends BaseObject {
	private Integer studentId;
	private String grade;
	private Boolean processed;

	/**       @hibernate.id
     *             column="student_id"
     *         
     */

	public Integer getStudentId() {
		return studentId;
	}

	public void setStudentId(Integer studentId) {
		this.studentId = studentId;
	}

	/**       
     *      *            @hibernate.property
     *             column="grade"
     *         
     */
	public String getGrade() {
		return grade;
	}

	public void setGrade(String grade) {
		this.grade = grade;
	}

	/**       
     *      *            @hibernate.property
     *             column="processed"
     *         
     */
	public Boolean getProcessed() {
		return processed;
	}

	public void setProcessed(Boolean processed) {
		this.processed = processed;
	}

	@Override
	public String toString() {
		return "MoodleGrade [studentId=" + studentId + ", grade=" + grade
				+ ", processed=" + processed + "]";
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((grade == null) ? 0 : grade.hashCode());
		result = prime * result
				+ ((processed == null) ? 0 : processed.hashCode());
		result = prime * result
				+ ((studentId == null) ? 0 : studentId.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		MoodleGrade other = (MoodleGrade) obj;
		if (grade == null) {
			if (other.grade != null)
				return false;
		} else if (!grade.equals(other.grade))
			return false;
		if (processed == null) {
			if (other.processed != null)
				return false;
		} else if (!processed.equals(other.processed))
			return false;
		if (studentId == null) {
			if (other.studentId != null)
				return false;
		} else if (!studentId.equals(other.studentId))
			return false;
		return true;
	}

}
